package cn.dakaqi.group.services;

import cn.dakaqi.entities.Group;
import cn.dakaqi.utils.exception.ServiceRuntimeException;
import org.springframework.data.domain.Page;

import java.util.List;

/**
 * Created by chunyang on 2016/3/21.
 */
public interface GroupService
{
    public void save(String jsonData)throws ServiceRuntimeException;
    public void save(Group group)throws ServiceRuntimeException;
    public void update(Group group)throws ServiceRuntimeException;
    public void delGroup(String groupCode)throws ServiceRuntimeException;
    public void delGroup(Long id)throws ServiceRuntimeException;
    public Group findByGroupCode(String groupCode)throws ServiceRuntimeException;
    public Group findOne(Long id)throws ServiceRuntimeException;
    public Page<Group> queryByName(String name)throws ServiceRuntimeException;
    Page<Group> searchByName(String name,int pageNumber)throws ServiceRuntimeException;
    void dissolve(String param);
    void joinOrg(String param)throws ServiceRuntimeException;
    void joinOrg(String groupCode,long platform,String parentCode,String memberCode,int status)throws ServiceRuntimeException;
    List<Group> findNameLike(String name,int size)throws ServiceRuntimeException;
    List<Group> findServiceFieldLike(String content,int size)throws ServiceRuntimeException;
    List<Group> findByCity(String city,int size)throws ServiceRuntimeException;
    List<Group> findHot(int size) throws ServiceRuntimeException;
}
